package net.goutalk.glcs.module.oa.service.impl;

import com.github.yulichang.base.MPJBaseServiceImpl;
import net.goutalk.glcs.module.oa.entity.News;
import net.goutalk.glcs.module.oa.mapper.NewsMapper;
import net.goutalk.glcs.module.oa.service.INewsService;
import lombok.AllArgsConstructor;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * <p>
 * 新闻中心表 服务实现类
 * </p>
 *
 * @author zlf
 * @since 2022-06-16
 */
@Service
@AllArgsConstructor
public class NewsServiceImpl extends MPJBaseServiceImpl<NewsMapper, News> implements INewsService {

    private final NewsMapper newsMapper;


    @Override
    @Transactional(rollbackFor = Exception.class)
    public boolean delete(List<Long> ids) {

        newsMapper.deleteBatchIds(ids);

        return true;
    }
}
